package com.atguigu.tingshu;

import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;
import com.atguigu.tingshu.model.album.AlbumInfo;
import com.atguigu.tingshu.model.album.BaseCategory3;
import org.springframework.beans.factory.BeanFactory;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
import org.springframework.cloud.openfeign.EnableFeignClients;
import org.springframework.context.ConfigurableApplicationContext;
import org.springframework.scheduling.annotation.EnableScheduling;

import java.util.ArrayList;
import java.util.List;

@SpringBootApplication
@EnableDiscoveryClient
@EnableFeignClients
@EnableScheduling
public class ServiceAlbumApplication {

    public static void main(String[] args) {
        ConfigurableApplicationContext run = SpringApplication.run(ServiceAlbumApplication.class, args);
        Object redisTemplate = run.getBean("redisTemplate");
        System.out.println(redisTemplate);
    }
//public static void main(String[] args) {
//    String content = """
//            {
//                "albumIntro": "经典 流行 从来都不冲突在这里，听见你曾经的故事新浪微博：主播小D小红书：小D就是我抖音号：52915017666",
//                "albumRichIntro": "123",
//                "category3Id": 1261,
//                "coverUrl": "https://imagev2.xmcdn.com/group50/M08/FA/D2/wKgKnVvr9vHzmc2XAAUu-Wm_RSg359.jpg",
//                "createTime": 1680627927000,
//                "discount": -1.0,
//                "estimatedTrackCount": 55,
//                "id": 2,
//                "includeTrackCount": 55,
//                "isDeleted": 0,
//                "isFinished": 1,
//                "isOpen": "0",
//                "param": {},
//                "payType": "0101",
//                "price": 0.00,
//                "priceType": "0202",
//                "qualityScore": "0.00",
//                "secondsForFree": 0,
//                "status": "0301",
//                "tracksForFree": 0,
//                "updateTime": 1697808844000,
//                "userId": 1,
//                "vipDiscount": -1.0
//            }
//            """;
//    AlbumInfo albumInfo = JSON.parseObject(content, AlbumInfo.class);
//    System.out.println(albumInfo);
//}

}
